import request from '@/utils/request'

// 获取一级城市列表
export const getCityList = () => {
  return request.get('/area/city', {
    params: {
      level: 1
    }
  })
}
// 获取热门城市
export const getHotCityName = () => {
  return request.get('/area/hot')
}

// 获取找房
export const searchHouse = (id) => {
  return request.get('/houses', {
    params: {
      cityId: id
    }
  })
}
// 获取子级市
export const cityTwo = (id) => {
  return request.get('/area', {
    params: {
      id
    }
  })
}
// 状态栏切换
export const tabSearchCityList = (data) => {
  return request.get('/houses', {
    params: data
  })
}
